1. Field of the Invention
The present invention relates to a compression method of halftone image data, for compressing data of halftone images including medical images such as an X-ray image, CT image, and the like.
2. Description of the Prior Art
Along with the development of digital techniques, halftone images are converted to digital data, and the digital halftone image data are stored, transferred, and subjected to a variety of digital image processing. However, a halftone image has a larger data volume than that of a binary image. Therefore, a large data volume when the halftone image is converted to digital data poses a problem. In particular, in medical images, e.g., an X-ray photograph of the thorex of a patient, the number of pixels upon digitization and the number of bits necessary for each pixel are respectively very large, i.e., four million pixels and 8 to 10 bits, resulting in poor efficiency of data storage and transfer.
A data compression technique for compressing a very large volume of data of a halftone image including a medical image has received a lot of attention.
The data compression technique can be roughly classified into reversible compression and irreversible compression. Since a low compression ratio of about 1/2 to 1/3 can only be expected in the reversible compression method, an irreversible compression method capable of obtaining a high compression ratio of 1/5 or higher, in particular, a transform coding method is receiving a great deal of attention.
The transform coding method is one of irreversible compression methods, and is most suitable for compressing a halftone image. In this method, the entire image is divided into small blocks, and orthogonal transformation is performed in units of blocks to obtain transform coefficients. The transform coefficients are quantized to code the original image.
In the transform coding method, it is known that a distribution of AC components of the transform coefficients can be approximated to a Gaussian distribution having a peak at zero. It is reported that when quantization of the transform coefficients having such a distribution is classified into Mid-riser quantization including "zero" in quantization levels, and Mid-trace quantization including "zero" in quantization output levels, the Mid-trace quantization is preferable since random noise components generated upon image reconstruction are small. However, when a Mid-trace type quantizer is used, if a compression ratio is increased, a pattern image inherent to components undesirably appears. Thus, if image processing such as enlargement, gray scale modification, frequency domain processing, or the like is performed, an unnatural image appears, and reproducibility of an original image is impaired.
When Mid-trace quantization is performed, image quality of a reconstructed image strongly depends on the number of AC components quantized to zero in a quantization process upon compression. More specifically, images in blocks of a reconstructed image are converted to a weighted sum of patterns inherent to AC components which are quantized to levels other than zero. Therefore, if the number of AC components quantized to levels other than zero is small, a pattern image inherent to components appears in the reconstructed image. In order to suppress appearance of the pattern image inherent to components, a quantization interval of a quantization level causing quantization output level to be zero is narrowed to decrease the number of AC components quantized to zero. However, in this case, an average code length upon coding is increased, thus decreasing a compression ratio.
Thus, it was found that if the frequency of generation of AC components quantized to zero is checked in units of blocks to detect a block in which a pattern image inherent to components tends to appear, and if a quantization interval of the detected block is narrowed, a reconstructed image in which appearance of a pattern image is suppressed can be obtained.
In the conventional technique, as parameters for determining a quantization interval, a square sum, a variance, an absolute value sum, and a standard deviation of AC components are used. In these parameters, however, round-off of data by quantization, in particular, round-off when components are quantized to zero, is not taken into consideration upon determination of the quantization interval. In addition, the quantization interval tends to be largely influenced by values of components having large absolute values.
In accordance with a principle of this invention, when the quantization interval is determined, round-off of components quantized to zero must be considered, and the quantization interval should not be largely influenced by the values of components having large absolute values. This principle is very important when Mid-trace quantization is performed as described above.
As a means for realizing a quantization interval determination method, the present invention proposes the following three methods.